package net.sevear.chaos.view
{
	import flash.events.MouseEvent;
	
	import mx.containers.Canvas;
	import mx.controls.Label;
	
	public class PauseBtn extends Canvas
	{
		private var _seleced:Boolean = false;
		private var lbl:Label;
		public function PauseBtn()
		{
			super();
			this.buttonMode = true;
			this.width =  540;
			this.height = 358;
			
			this.graphics.clear();
			this.graphics.beginFill(0xdbdbdb,0.66);
			this.graphics.drawRect(0,0,this.width,this.height);
			
			this.graphics.beginFill(0x9c9c9c,0.99);
			this.graphics.drawRoundRect((this.width-120)/2,(this.height-40)/2,
				120,40,10,10);
			this.graphics.endFill();
			
			lbl = new Label();
			lbl.setStyle("color",0xffffff);
			lbl.setStyle("textAlign",'center');
			lbl.width = 80;
			lbl.horizontalCenter= 0;
			lbl.verticalCenter = 0;
			lbl.text = "继续收听>>";
			this.addChild(lbl);
		}
		
		public function get selected():Boolean{
			return _seleced;
		}
		
		public function set selected(value:Boolean):void{
			_seleced = value;
			if(value==false){
				this.visible = false;
			}else{
				this.visible = true;
			}
		}
	}
}